﻿using System;
using System.Collections.Generic;
using System.Text;
using ArkEC.SEMs.BizObject.UM;
using System.Data.Common;
using ArkEC.SEMs.DataAccess;
using ArkEC.SEMs.DataAccess.UM;

namespace ArkEC.SEMs.Business.UM
{
    /// <summary>
    /// 用户业务处理
    /// </summary>
    public class UserService
    {
        /// <summary>
        /// 通过邮箱和密码获取用户数据
        /// </summary>
        /// <param name="email"></param>
        /// <param name="pwd"></param>
        /// <returns></returns>
        public static User QueryUser(Dictionary<string, string> paramObj)
        {
            using (DbConnection conn = ConnFactory.CreateConn())
            {
                conn.Open();
                return UserDAFactory.CreateUserDA().QueryUser(conn, null, paramObj["Email"], paramObj["Pwd"]);
            }
        }
    }
}
